<?php

namespace App\Requests\Api\CourseStudent;

use Illuminate\Foundation\Http\FormRequest;

/**
 * 用户列表校验
 * Class ListReques
 * @package App\Requests\Api\CourseStudent
 */
class ListRequest extends FormRequest {
    public function authorize()
    {
        return true;
    }

    public function rules()
    {
        return [
            'q'           => 'nullable|string|max:256',
        ];
    }

    public function messages()
    {
        return [
            'q.string'           => '关键字必须是字符串',
            'q.max'              => '关键字长度过大',
        ];
    }
}